const Parse = require('./parse')
const p = new Parse()
const net = require('net')
const client = net.createConnection({ port: 8000, host: '127.0.0.1' }, () => {
  client.write('GET / HTTP/1.1\r\nHost: 127.0.0.1\r\n\r\n');
});
client.on('data', (data) => {
  // console.log(data.toString());
  p.write(data.toString())
  client.end();
});
client.on('end', () => {
  console.log('disconnected from server');
  p.end()
});


